package com.zhen.mybatis.web;

import com.zhen.mybatis.domain.User;
import com.zhen.mybatis.service.UserService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
public class AreaController {
    @Autowired
    UserService userService;
    @PostMapping("/save")
    public void getAllArea() {
        User user = new User();
        user.setAge(12);
        user.setName("zhangsan");
        user.setId(111L);
        userService.save(user);
    }
}
